package com.seari.bean.ats;

import com.seari.utils.DataUtil;

/**
 * 卡斯柯消息ID枚举
 */
public enum AtsMessageIDCodeEnum {

    ATS_CIOS_TRAIN_LOCATION(0x1001,"ATS_CIOS_TRAIN_LOCATION"),
    ATS_CIOS_BLOCK_INFO(0x1002,"ATS_CIOS_BLOCK_INFO"),
    ATS_CIOS_PLANNED_TRAIN_DATA(0x1003,"ATS_CIOS_BLOCK_INFO"),
    ATS_CIOS_PRACTICAL_TRAIN_DATA(0x1004,"ATS_CIOS_PRACTICAL_TRAIN_DATA"),
    ATS_CIOS_DYNAMIC_TRAIN_DATA(0x1005,"ATS_CIOS_ DYNAMIC_TRAIN_DATA"),
    ATS_CIOS_DATA_START(0x1101,"ATS_CIOS_DATA_START"),
    ATS_CIOS_DATA_CONTENT(0x1102,"ATS_CIOS_DATA_CONTENT"),
    ATS_CIOS_DATA_END(0x1103,"ATS_CIOS_DATA_END"),
    //请求计划列车运行信息
    CIOS_ATS_REQUEST_PLANNED_TRAIN_DATA(0x2002,"CIOS_ATS_REQUEST_PLANNED_TRAIN_DATA"),
    //请求实际列车运行信息
    CIOS_ATS_REQUEST_PRACTICAL_TRAIN_DATA(0x2003,"CIOS_ATS_REQUEST_PRACTICAL_TRAIN_DATA"),
    //车站火灾信息及位置(CIOS_ATS_FAS_INFO) 
    CIOS_ATS_FAS_INFO(0x2004,"CIOS_ATS_FAS_INFO"),
    //牵引分段信息
    CIOS_ATS_SCADA_INFO(0x2005,"CIOS_ATS_SCADA_INFO"),
    //隧道风机开启及风向
    CIOS_ATS_BAS_INFO(0x2006,"CIOS_ATS_BAS_INFO"),
    // 心跳
    MESSAGE_POLLING(0x3001,"MESSAGE_POLLING");

    private Integer code;
    private String message;

    AtsMessageIDCodeEnum(Integer code, String message){
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }

    public static void main(String args[]) {
        System.out.println(AtsMessageIDCodeEnum.CIOS_ATS_REQUEST_PLANNED_TRAIN_DATA.getCode()&0xff);
        String hexString = Integer.toHexString(AtsMessageIDCodeEnum.CIOS_ATS_REQUEST_PLANNED_TRAIN_DATA.getCode());
        System.out.println("hexString="+hexString);
        
        
        System.out.println("/******************/");
        
        
        
        
    }
    
}
